]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
NetworkMenu: fix updating the access point strength
authorGiovanni Campagna <gcampagna@src.gnome.org>
Fri, 1 Apr 2011 13:42:00 +0000 (15:42 +0200)
committerDan Winship <danw@gnome.org>
Mon, 11 Apr 2011 14:38:00 +0000 (10:38 -0400)
A notify signal does not include the new value of the property in
its signature, so the handler was trying to compare a GParamSpec with
a number when updating. Fix it to always retrieve the value from the
object.

https://bugzilla.gnome.org/show_bug.cgi?id=646443

js/ui/status/network.js

index 88521888a5070c6055087f3a1b7e9ab3008ebbe9..752a9f6462333f43d0e8ac7ad6d38dfb729411c5 100644 (file)
@@ -132,8 +132,8 @@ NMNetworkMenuItem.prototype = {
         }
     },
 
-    _updated: function(ap, strength) {
-        if (strength > this.bestAP.strength)
+    _updated: function(ap) {
+        if (ap.strength > this.bestAP.strength)
             this.bestAP = ap;
 
         this._signalIcon.icon_name = this._getIcon();